package vip.xiaonuo.sys.fymodule.order.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

import java.io.Serializable;
import java.math.BigDecimal;

/**
 * <p>
 * 订单详情
 * </p>
 *
 * @author wangy
 * @since 2025-06-18
 */
@Data
@TableName("sxo_order_detail")
@Schema(name = "SxoOrderDetail对象", description = "订单详情")
public class SxoOrderDetail implements Serializable {

    private static final long serialVersionUID = 1L;

    @Schema(description = "自增id")
    @TableId(value = "id", type = IdType.AUTO)
    private String id;

    @Schema(description = "用户id")
    @TableField("user_id")
    private String userId;

    @Schema(description = "订单id")
    @TableField("order_id")
    private String orderId;

    @Schema(description = "商品id")
    @TableField("goods_id")
    private String goodsId;

    @Schema(description = "标题")
    @TableField("title")
    private String title;

    @Schema(description = "封面图片")
    @TableField("images")
    private String images;

    @Schema(description = "原价")
    @TableField("original_price")
    private BigDecimal originalPrice;

    @Schema(description = "价格")
    @TableField("price")
    private BigDecimal price;

    @Schema(description = "当前总价(单价*数量)")
    @TableField("total_price")
    private BigDecimal totalPrice;

    @Schema(description = "规格")
    @TableField("spec")
    private String spec;

    @Schema(description = "购买数量")
    @TableField("buy_number")
    private Integer buyNumber;

    @Schema(description = "型号")
    @TableField("model")
    private String model;

    @Schema(description = "重量（kg）")
    @TableField("spec_weight")
    private BigDecimal specWeight;

    @Schema(description = "体积（m³）")
    @TableField("spec_volume")
    private BigDecimal specVolume;

    @Schema(description = "编码")
    @TableField("spec_coding")
    private String specCoding;

    @Schema(description = "条形码")
    @TableField("spec_barcode")
    private String specBarcode;

    @Schema(description = "退款金额")
    @TableField("refund_price")
    private BigDecimal refundPrice;

    @Schema(description = "退货数量")
    @TableField("returned_quantity")
    private Integer returnedQuantity;

    @Schema(description = "添加时间")
    @TableField("add_time")
    private String addTime;

    @Schema(description = "更新时间")
    @TableField("upd_time")
    private String updTime;
}
